package neu.soft.feignclient;

import neu.soft.entity.Invoice;
import neu.soft.vo.ResultBean;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

import java.util.Map;

@Component
@FeignClient(value = "financial-server",fallbackFactory =FinacialFeignClientFallBackFactory.class)
public interface FinancialFeignClient {


    @PostMapping("/invoice/add")
    ResultBean<Invoice> add(@RequestBody Map<String, Object> map);



    @PostMapping("/get")
    public ResultBean<Invoice> get(@RequestBody String orderId);
}
